﻿using System;
using System.Data;
using System.Configuration;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Data.SqlClient;

namespace BTN04.DAO
{
    public class KhuyenMaiDAO
    {
        public DataTable LayDanhSachKhuyenMai()
        {
            string sql = "Select * From KhuyenMai";
            SqlConnection cnn = new SqlConnection(DataProvider.ConnectionString);
            cnn.Open();
            SqlCommand cmd = new SqlCommand(sql, cnn);
            SqlDataAdapter adapter = new SqlDataAdapter(cmd);
            DataTable dt = new DataTable();
            adapter.Fill(dt);
            cnn.Close();
            return dt;
        }

    }
}
